package com.tuo51.childcare.repository;

import com.tuo51.childcare.domain.bize.BizEvaluateQuestion;
import org.springframework.data.jpa.repository.JpaRepository;
import org.springframework.data.jpa.repository.Modifying;
import org.springframework.data.jpa.repository.Query;
import org.springframework.stereotype.Repository;

import java.util.List;

@Repository
public interface BizEvaluateQuestionRepository extends JpaRepository<BizEvaluateQuestion,String> {

    @Modifying
    @Query
    void deleteAllBySheetId(String sheetId);

    List<BizEvaluateQuestion> findAllBySheetIdAndDeletedIsFalseOrderByIndexOnPaper(String sheetId);
}
